<body class="wy-body">
<div class="layui-fluid">
	<div class="layui-card">
		<div class="layui-form layui-card-header wy-card-header-auto">
			<div class="layui-form-item">
				<form action="{:url(request()->action())}" method="get">
				<div class="layui-inline">
					<label class="layui-form-label wy-width-auto">广告位ID</label>
					<div class="layui-input-inline">
						<input type="text" name="id" placeholder="请输入" autocomplete="off" class="layui-input" value="{$get_data.id}">
					</div>
				</div>
				<div class="layui-inline">
					<label class="layui-form-label wy-width-auto">广告位名称</label>
					<div class="layui-input-inline">
						<input type="text" name="name" placeholder="请输入" autocomplete="off" class="layui-input" value="{$get_data.name}">
					</div>
				</div>
				<div class="layui-inline">
					<button class="layui-btn">
						<i class="layui-icon layui-icon-search"></i>
					</button>
				</div>
				</form>
			</div>
		</div>

		<div class="layui-card-body">
<table class="layui-table" name="wy_table_lists" lay-filter="wy_table_lists"
	lay-data="{
		height:'full-118',
		cellMinWidth:'180',
		url:'{:url('ajax_lists')}',
		where: {
				{$get_str}
			},
		method:'post',
		page:true,
		id:'wy_table_lists',
		limits:[15,30,50,100]}"
>
<thead>
<tr>
	<th lay-data="{field:'id',templet:'#tpl_id'}">ID</th>
	<th lay-data="{field:'name',templet:'#tpl_name'}">广告位名称</th>
	<th lay-data="{field:'num_all',templet:'#tpl_num_all'}">全部广告数</th>
	<th lay-data="{field:'num_valid_1',templet:'#tpl_num_valid_1'}">展示中广告</th>
	<th lay-data="{field:'num_valid_2',templet:'#tpl_num_valid_2'}">未开始广告数</th>
	<th lay-data="{field:'num_error',templet:'#tpl_num_valid_0'}">已结束广告数</th>
	<th lay-data="{field:'num_error',templet:'#tpl_num_error'}">已关闭广告数</th>
	<th lay-data="{field:'info'}">描述</th>
</tr>
</thead>
</table>

		</div>
	</div>
</div>
<script type="text/html" id="tpl_id">
    <a class="layui-table-link wy_but" 
		wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}" 
		wy-event="lay_parent_tab"
		wy-id="bannerimages_index"
		wy-title="广告管理"
	>{{d.id}}</a>
</script>
<script type="text/html" id="tpl_name">
     <a class="layui-table-link wy_but" 
		wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}" 
		wy-event="lay_parent_tab"
		wy-id="bannerimages_index"
		wy-title="广告管理"
	>{{d.name}}</a>
</script>
<script type="text/html" id="tpl_num_all">
	{{#  if(d.num_all > 0){ }}
		 <a class="layui-table-link wy_but" 
			wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}" 
			wy-event="lay_parent_tab"
			wy-id="bannerimages_index"
			wy-title="广告管理"
		>{{d.num_all}}</a>
	{{#  } else { }}
		{{d.num_all}}
	{{#  } }}
</script>
<script type="text/html" id="tpl_num_valid_1">
	{{#  if(d.num_valid_1 > 0){ }}
		 <a class="layui-table-link wy_but" 
			wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}&status=1" 
			wy-event="lay_parent_tab"
			wy-id="bannerimages_index"
			wy-title="广告管理"
		>{{d.num_valid_1}}</a>
	{{#  } else { }}
		{{d.num_valid_1}}
	{{#  } }}
</script>
<script type="text/html" id="tpl_num_valid_2">
	{{#  if(d.num_valid_2 > 0){ }}
		 <a class="layui-table-link wy_but" 
			wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}&status=2" 
			wy-event="lay_parent_tab"
			wy-id="bannerimages_index"
			wy-title="广告管理"
		>{{d.num_valid_2}}</a>
	{{#  } else { }}
		{{d.num_valid_2}}
	{{#  } }}
</script>
<script type="text/html" id="tpl_num_valid_0">
	{{#  if(d.num_valid_0 > 0){ }}
		 <a class="layui-table-link wy_but" 
			wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}&status=3" 
			wy-event="lay_parent_tab"
			wy-id="bannerimages_index"
			wy-title="广告管理"
		>{{d.num_valid_0}}</a>
	{{#  } else { }}
		{{d.num_valid_0}}
	{{#  } }}
</script>
<script type="text/html" id="tpl_num_error">
	{{#  if(d.num_error > 0){ }}
		 <a class="layui-table-link wy_but" 
			wy-url="{:url('Bannerimages/index')}?cat_id={{d.id}}&status=4" 
			wy-event="lay_parent_tab"
			wy-id="bannerimages_index"
			wy-title="广告管理"
		>{{d.num_error}}</a>
	{{#  } else { }}
		{{d.num_error}}
	{{#  } }}
</script>
</body>